package com.atguigu.guli.serviceedu.service;

import com.atguigu.guli.serviceedu.entity.Course;
import com.atguigu.guli.serviceedu.entity.query.CourseQuery;
import com.atguigu.guli.serviceedu.entity.vo.CoursePublishVo;
import com.atguigu.guli.serviceedu.entity.vo.CourseInfoVo;
import com.atguigu.guli.serviceedu.entity.vo.CourseQueryVo;
import com.atguigu.guli.serviceedu.entity.vo.CourseWebVo;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.List;
import java.util.Map;

/**
 * <p>
 * 课程 服务类
 * </p>
 *
 * @author atguigu
 * @since 2021-08-01
 */
public interface CourseService extends IService<Course> {

    String saveCourse(CourseInfoVo courseInfoVo);

    CourseInfoVo getCourseInfoById(Long id);

    void updateCourseInfoById(CourseInfoVo courseInfoVo);

    CoursePublishVo getCoursePublishVoById(String id);

    void publishCourseById(String id);

    void pageQuery(Page<Course> pageParam, CourseQuery courseQuery);

    List<Course> listByTeacherId(String teacherId);

    Map<String, Object> pageListWeb(Page<Course> pageParam, CourseQueryVo courseQuery);

    CourseWebVo selectInfoWebById(String id);

    void updatePageViewCount(String id);
}
